<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <!-- 单页应用 -->
    <div id="app">
      <!-- 声明式渲染 -->
      <h1>{{title}}</h1>
      <p>欢迎{{author}}</p>
    </div>

    <script src="./vue.min.js"></script>
    <script>
      new Vue({
        //data和el都是关键字
        el: '#app', //使用css3选择器语法指定element
        data: {
          title: '第一个vue程序',
          author: 'chanzany',
          user: {
            username: 'root',
            password: '123',
          },
        },
      })
    </script>
  </body>
</html>
